import request from '@/utils/request'
import userInfo from "../../vue-admin/src/api/userInfo";

const api_name = `/api/user`

export default {
  //手机登录
  login(userInfo) {
    return request({
      url: `${api_name}/login`,
      method: `post`,
      data: userInfo
    })
  },

  //用户认证
  saveUserAuth(userAuth) {
    return request({
      url: `${api_name}/auth/userAuth`,
      method: 'post',
      data: userAuth
    })
  },
  //根据userId获取用户信息
  getUserInfo() {
    return request({
      url: `${api_name}/auth/getUserInfo`,
      method: `get`
    })
  },
  fileUrl() {
    return request({
      url: `http://localhost:8080/api/oss/file/fileUpload`,
      method: `post`,
    })
  },

}
